home *** CD-ROM | disk | FTP | other *** search
/ Mac-Source 1994 July / Mac-Source_July_1994.iso / C and C++ / Libraries / EleOfC++ vrs 0.1 / TextEdit / TTEApp.c < prev    next >
Encoding:
C/C++ Source or Header  |  1991-07-14  |  944 b   |  51 lines  |  [TEXT/KAHL]

  1. /*
  2. ** This is the TTEApp class definition.  This class is an adaptation of 
  3. ** the class of the same name in the book, Elements of C++ Macintosh 
  4. ** Programming, by Dan Weston.
  5. **
  6. ** Copyright © 1991 Mark Gross 
  7. ** (RR2, Box 84, Clayville, NY 13322);         
  8. ** this file may be published everywhere, but no charge
  9. ** may be made for its use.  Please contact me about any bugs found.
  10. ** I'm also looking for Macintosh development work, so drop me a line
  11. ** if you think I could help.  
  12. */
  13.  
  14. #include "TTEApp.h"
  15. #include "TTEDoc.h"
  16. #include <oops.h>
  17.  
  18. TDoc*    TTEApp::MakeDoc(SFReply *reply)
  19. {
  20.     TDoc *tempDoc;
  21.     
  22.     tempDoc = (TTEDoc *) new(TTEDoc);
  23.     tempDoc->Init(GetCreator(), reply);
  24.     return tempDoc;
  25. }/*end function*/
  26.  
  27.  
  28. void    TTEApp::GetFileTypeList(void)
  29. {
  30.     fFileTypeList[0] = 'TEXT';
  31. }
  32.  
  33.  
  34. int        TTEApp::GetNumFileTypes(void)
  35. {
  36.     return 1;
  37. }
  38.  
  39.  
  40. Boolean        TTEApp::CanOpen(void)
  41. {
  42.     return TRUE;
  43. }
  44.  
  45.  
  46. OSType        TTEApp::CanAcceptClipType(void)
  47. {
  48.     return 'TEXT';
  49. }
  50.  
  51.